package com.joesem.sale.client.network

import com.google.gson.Gson

/**
 * @Time 2023/2/27 15:25:06
 * @Description
 **/
class LoginException(val msg: String?) : Throwable(msg) {
}


inline fun <reified MODE> MODE?.toJson(): String {
    return try {
        if (this == null)
            ""
        else
            Gson().toJson(MODE::class.java)
    } catch (e: Exception) {
        ""
    }
}